﻿<phone:PhoneApplicationPage 
	xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
	xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
	xmlns:phone="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone"
	xmlns:shell="clr-namespace:Microsoft.Phone.Shell;assembly=Microsoft.Phone"
	xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
	xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
	mc:Ignorable="d" d:DesignWidth="480" d:DesignHeight="768"
	x:Class="PhoneAppProject1.Detail_News"
	FontFamily="{StaticResource PhoneFontFamilyNormal}"
	FontSize="{StaticResource PhoneFontSizeNormal}"
	Foreground="{StaticResource PhoneForegroundBrush}"
	Orientation="Portrait"
	shell:SystemTray.IsVisible="True" Loaded="PhoneApplicationPage_Loaded">
	<phone:PhoneApplicationPage.Resources>
		<DataTemplate x:Key="myItems">
			<Grid Width="440" Height="218" Margin="0" Background="#00FBFBFB">
				<Grid.RowDefinitions>
					<RowDefinition Height="Auto" MinHeight="57.333"/>
					<RowDefinition/>
				</Grid.RowDefinitions>
				<Grid.ColumnDefinitions>
					<ColumnDefinition Width="0.262*"/>
					<ColumnDefinition Width="0.738*"/>
				</Grid.ColumnDefinitions>
				<Border BorderBrush="#FF6E6E6E" BorderThickness="4" Height="2" Margin="12,4,20,0" VerticalAlignment="Top" Grid.ColumnSpan="2" Background="#FF606060" Visibility="Collapsed"/>
				<Image Margin="8,13.667,8,19" Source="{Binding ImageURL}" Grid.Row="1" d:LayoutOverrides="HorizontalAlignment"/>
				<TextBlock Grid.Column="1" Margin="8,13.667,25,37" TextWrapping="Wrap" Text="{Binding Message}" FontSize="17.333" Foreground="Black" Grid.Row="1" FontFamily="Lucida Sans Unicode"/>
				<TextBlock Grid.Column="1" Height="26" Margin="8,5,52,8" TextWrapping="Wrap" Text="{Binding CreateDate}" VerticalAlignment="Bottom" FontSize="14.667" Foreground="#FF4E4E4E" Grid.Row="1" FontFamily="Lucida Sans Unicode"/>
				<TextBlock Margin="12,6,52,8" TextWrapping="Wrap" FontSize="21.333" Foreground="#FF1B1B1B" FontWeight="Bold" Text="{Binding Title}" Grid.ColumnSpan="2" FontFamily="Lucida Sans Unicode" RenderTransformOrigin="0.5,0.5" />
			</Grid>
		</DataTemplate>
		<Style x:Key="btnRefresh" TargetType="Button">
			<Setter Property="Background" Value="Transparent"/>
			<Setter Property="BorderBrush" Value="{StaticResource PhoneForegroundBrush}"/>
			<Setter Property="Foreground" Value="{StaticResource PhoneForegroundBrush}"/>
			<Setter Property="BorderThickness" Value="{StaticResource PhoneBorderThickness}"/>
			<Setter Property="FontFamily" Value="{StaticResource PhoneFontFamilySemiBold}"/>
			<Setter Property="FontSize" Value="{StaticResource PhoneFontSizeMediumLarge}"/>
			<Setter Property="Padding" Value="10,3,10,5"/>
			<Setter Property="Template">
				<Setter.Value>
					<ControlTemplate TargetType="Button">
						<Grid Background="Transparent">
							<VisualStateManager.VisualStateGroups>
								<VisualStateGroup x:Name="CommonStates">
									<VisualState x:Name="Normal"/>
									<VisualState x:Name="MouseOver"/>
									<VisualState x:Name="Pressed"/>
									<VisualState x:Name="Disabled"/>
								</VisualStateGroup>
							</VisualStateManager.VisualStateGroups>
							<Image Margin="3" Source="refreshicon.png"/>
						</Grid>
					</ControlTemplate>
				</Setter.Value>
			</Setter>
		</Style>
	</phone:PhoneApplicationPage.Resources>
	<phone:PhoneApplicationPage.Background>
		<ImageBrush/>
	</phone:PhoneApplicationPage.Background>

	<!--LayoutRoot is the root grid where all page content is placed-->
	<Grid x:Name="LayoutRoot">
		<Grid.Background>
			<ImageBrush Stretch="Fill" ImageSource="BG.png"/>
		</Grid.Background>
		<Grid.RowDefinitions>
			<RowDefinition Height="Auto"/>
			<RowDefinition Height="*"/>
		</Grid.RowDefinitions>
		
		<!--TitlePanel contains the name of the application and page title-->

		<!--ContentPanel - place additional content here-->
		<Grid Grid.RowSpan="2" Opacity="0.8" Canvas.ZIndex="-1">
			<Grid.Background>
				<ImageBrush Stretch="Fill" ImageSource="bg_white.jpg"/>
			</Grid.Background>
			<ProgressBar x:Name="myProgress" Height="24" Margin="75,392,85,0" VerticalAlignment="Top" Width="320" d:LayoutOverrides="HorizontalAlignment"/>
<!--TitlePanel contains the name of the application and page title-->

		<!--ContentPanel - place additional content here-->
		</Grid>
		<StackPanel x:Name="TitlePanel" Grid.Row="0" Margin="12,17,0,28" Grid.RowSpan="2">
			<Grid Height="100">
				<TextBlock x:Name="PageTitle" Margin="1,13,8,0" Style="{StaticResource PhoneTextTitle1Style}" Foreground="Black" FontWeight="Bold" FontFamily="Bodoni MT" d:LayoutOverrides="Height" FontSize="64"/>
				<Button x:Name="btnRefresh" Content="Button" HorizontalAlignment="Right" Height="42" Width="58" Style="{StaticResource btnRefresh}" Click="btnRefresh_Click" RenderTransformOrigin="5.31,-0.357" Margin="0,0,50,0" VerticalAlignment="Bottom"/>
			</Grid>
			<Border BorderBrush="#FF094515" BorderThickness="1,0,1,1" Height="3" Margin="12,0,61,0" Background="#ED00470E"/>
			<ListBox x:Name="ListItem" ItemTemplate="{StaticResource myItems}" Background="{x:Null}" Height="594" Margin="0,6,36,0" SelectionChanged="ListItem_SelectionChanged"/>
		</StackPanel>
	</Grid>
</phone:PhoneApplicationPage>